﻿using System;

namespace AngularJS
{
    //TODO:
    public class HttpConfig
    {
        public string Method;
        public string Url;
        public object Params;
        public object Data;
        public object Headers;// – {Object} – Map of strings or functions which return strings representing HTTP headers to send to the server. If the return value of a function is null, the header will not be sent.
        public string XsrfHeaderName;
        public string XsrfCookieName;
        //public Func<object, object> TransformRequest;
        //public Func<object, object> TransformResponse;        
        public object Cache;
        public object Timeout;
        public bool WithCredentials;
        public string ResponseType;
    }

    public class Http
    {
        public IPromise Delete(string url, HttpConfig config = null)
        {
            return null;
        }

        public IPromise Get(string url, HttpConfig config = null)
        {
            return null;
        }

        public IPromise Head(string url, HttpConfig config = null)
        {
            return null;
        }

        public IPromise Jsonp(string url, HttpConfig config = null)
        {
            return null;
        }

        public IPromise Post(string url, object data, HttpConfig config = null)
        {
            return null;
        }

        public IPromise Put(string url, object data, HttpConfig config = null)
        {
            return null;
        }
    }
}
